package com.regent.central.bill.repository.mrp.dto;

/**
 * 采购单到料状态QTO
 *
 * @author 钟宝林
 * @date 2018-06-23 15:02
 **/
public class BillPurchaseArriveStatusQTO {

    private String billMaterialPurchaseId;
    private int arriveStatusSum;
    private int count;

    public String getBillMaterialPurchaseId() {
        return billMaterialPurchaseId;
    }

    public void setBillMaterialPurchaseId(String billMaterialPurchaseId) {
        this.billMaterialPurchaseId = billMaterialPurchaseId;
    }

    public int getArriveStatusSum() {
        return arriveStatusSum;
    }

    public void setArriveStatusSum(int arriveStatusSum) {
        this.arriveStatusSum = arriveStatusSum;
    }

    public int getCount() {
        return count;
    }

    public void setCount(int count) {
        this.count = count;
    }

    public boolean isInitial() {
        return arriveStatusSum <= 0;
    }

    public boolean isProcessing() {
        return arriveStatusSum > 0 && arriveStatusSum < count * 2;
    }

    public boolean isCompleted() {
        return arriveStatusSum == count * 2;
    }
}
